package com.neusoft.nepm.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.neusoft.nepm.service.INotificationService;
import com.neusoft.nepm.dto.NotificationRequestDto;

@RestController
@RequestMapping("/notifications")
public class NotificationController {

    @Autowired
    private INotificationService notificationService;

    @PostMapping("/send")
    public boolean sendNotification(@RequestBody NotificationRequestDto request) {
        return notificationService.sendNotification(request);
    }
}
